public class AccountBook {
    private String accountName;
    private double income;
    private double outcome;
    public AccountBook(String accountName, double income, double outcome) {
        this.accountName = accountName;
        this.income = income;
        this.outcome = outcome;
    }
    public double compute() {
        return income - outcome;
    }
    public String getAccountName() {
        return accountName;
    }
    public double getIncome() {
        return income;
    }
    public double getOutcome() {
        return outcome;
    }

    public static class AccountBookTest {
            public static void main(String[] args) {
                AccountBook accountBook = new AccountBook("Zhangsan", 30, 10);
                System.out.println( accountBook.getAccountName());
                System.out.println("income:" + accountBook.getIncome());
                System.out.println("outcome:" + accountBook.getOutcome());
                System.out.println("balance:" + accountBook.compute());
            }
    }
}
